import request from '@/utils/request'

// 查询Kettle脚本列表
export function listTaskScript(query) {
  return request({
    url: '/schedule/taskScript/list',
    method: 'get',
    params: query
  })
}

// 查询Kettle脚本详细
export function getTaskScript(scriptId) {
  return request({
    url: '/schedule/taskScript/' + scriptId,
    method: 'get'
  })
}

// 新增Kettle脚本
export function addTaskScript(data) {
  return request({
    url: '/schedule/taskScript',
    method: 'post',
    data: data
  })
}

// 修改Kettle脚本
export function updateTaskScript(data) {
  return request({
    url: '/schedule/taskScript',
    method: 'put',
    data: data
  })
}

// 删除Kettle脚本
export function delTaskScript(scriptId) {
  return request({
    url: '/schedule/taskScript/' + scriptId,
    method: 'delete'
  })
}
